package com.example.weibowebcrawlerdemo.utils;

import java.util.UUID;

public class UUIDUtil {
    private static UUID uuid;

    /**
     * 使用UUID对象,随机生成一个11位数的唯一id (取消 `-` 符号)
     * */
    public static String getElevenIDCode(){
        uuid = UUID.randomUUID();
        return uuid.toString().replaceAll("-","").substring(21,32);
    }
}
